{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 43,
   "id": "380ce58a",
   "metadata": {},
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import pandas as pd\n",
    "import matplotlib.pyplot as plt"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "id": "57e2e9ae",
   "metadata": {
    "scrolled": true
   },
   "outputs": [],
   "source": [
    "df=pd.read_csv('E:/推荐系统/数据集/MovieLens/ml-latest/ratings.csv')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 50,
   "id": "f1baebfe",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>userId</th>\n",
       "      <th>movieId</th>\n",
       "      <th>rating</th>\n",
       "      <th>timestamp</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>307</td>\n",
       "      <td>3.5</td>\n",
       "      <td>1256677221</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>481</td>\n",
       "      <td>3.5</td>\n",
       "      <td>1256677456</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1</td>\n",
       "      <td>1091</td>\n",
       "      <td>1.5</td>\n",
       "      <td>1256677471</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>1</td>\n",
       "      <td>1257</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1256677460</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>1</td>\n",
       "      <td>1449</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1256677264</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27753439</th>\n",
       "      <td>283228</td>\n",
       "      <td>8542</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1379882795</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27753440</th>\n",
       "      <td>283228</td>\n",
       "      <td>8712</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1379882751</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27753441</th>\n",
       "      <td>283228</td>\n",
       "      <td>34405</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1379882889</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27753442</th>\n",
       "      <td>283228</td>\n",
       "      <td>44761</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1354159524</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>27753443</th>\n",
       "      <td>283228</td>\n",
       "      <td>54286</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1354159718</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>27753444 rows × 4 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "          userId  movieId  rating   timestamp\n",
       "0              1      307     3.5  1256677221\n",
       "1              1      481     3.5  1256677456\n",
       "2              1     1091     1.5  1256677471\n",
       "3              1     1257     4.5  1256677460\n",
       "4              1     1449     4.5  1256677264\n",
       "...          ...      ...     ...         ...\n",
       "27753439  283228     8542     4.5  1379882795\n",
       "27753440  283228     8712     4.5  1379882751\n",
       "27753441  283228    34405     4.5  1379882889\n",
       "27753442  283228    44761     4.5  1354159524\n",
       "27753443  283228    54286     4.5  1354159718\n",
       "\n",
       "[27753444 rows x 4 columns]"
      ]
     },
     "execution_count": 50,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "id": "4c3aa1fa",
   "metadata": {},
   "outputs": [],
   "source": [
    "df=df.iloc[0:500000]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "id": "cfb0df94",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "500000"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df['movieId'].size"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "62b49726",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "500000"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df['userId'].size"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "id": "63d33467",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "283228"
      ]
     },
     "execution_count": 36,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "len(df['userId'].unique())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 28,
   "id": "055cad9b",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "53889"
      ]
     },
     "execution_count": 28,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "len(df['movieId'].unique())"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "ff63dcf6",
   "metadata": {},
   "outputs": [],
   "source": [
    "# i=0\n",
    "# for name, result in df.groupby('userId'):\n",
    "#     if i<5:\n",
    "#         print(name)\n",
    "#         print(pd.DataFrame(result))\n",
    "#         print(\"______________\")\n",
    "#         i=i+1\n",
    "#     else:\n",
    "#         break"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "7dda1619",
   "metadata": {},
   "outputs": [],
   "source": [
    "def count(df,df_group,group_cols,new_feature_name):\n",
    "    df_group[new_feature_name]=1\n",
    "    df_group=df_group.groupby(group_cols).agg('sum').reset_index()\n",
    "    df=df.merge(df_group,on=group_cols,how='left')\n",
    "    return df\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "id": "6f95f927",
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "C:\\Users\\dell\\AppData\\Local\\Temp/ipykernel_6620/2865837117.py:2: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame.\n",
      "Try using .loc[row_indexer,col_indexer] = value instead\n",
      "\n",
      "See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  df_group[new_feature_name]=1\n"
     ]
    }
   ],
   "source": [
    "df_group=df[['userId']]\n",
    "df_userId=count(df,df_group,'userId','user_vitality')\n",
    "df_group=df[['movieId']]\n",
    "df_userId=count(df_userId,df_group,'movieId','movie_popularity')\n",
    "\n",
    "df1=df_userId[['userId','movie_popularity']].copy()\n",
    "df1=df1.groupby('userId').agg('sum').reset_index()\n",
    "df1.columns=['userId','movie_popularity_sum']\n",
    "df_userId=df_userId.merge(df1,on='userId',how='left')\n",
    "df_userId['movie_pop_ave']=df_userId['movie_popularity_sum']/df_userId['user_vitality']"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "id": "b0f63a05",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>userId</th>\n",
       "      <th>movieId</th>\n",
       "      <th>rating</th>\n",
       "      <th>timestamp</th>\n",
       "      <th>user_vitality</th>\n",
       "      <th>movie_popularity</th>\n",
       "      <th>movie_popularity_sum</th>\n",
       "      <th>movie_pop_ave</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>307</td>\n",
       "      <td>3.5</td>\n",
       "      <td>1256677221</td>\n",
       "      <td>16</td>\n",
       "      <td>167</td>\n",
       "      <td>2021</td>\n",
       "      <td>126.312500</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>481</td>\n",
       "      <td>3.5</td>\n",
       "      <td>1256677456</td>\n",
       "      <td>16</td>\n",
       "      <td>134</td>\n",
       "      <td>2021</td>\n",
       "      <td>126.312500</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>1</td>\n",
       "      <td>1091</td>\n",
       "      <td>1.5</td>\n",
       "      <td>1256677471</td>\n",
       "      <td>16</td>\n",
       "      <td>107</td>\n",
       "      <td>2021</td>\n",
       "      <td>126.312500</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>1</td>\n",
       "      <td>1257</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1256677460</td>\n",
       "      <td>16</td>\n",
       "      <td>109</td>\n",
       "      <td>2021</td>\n",
       "      <td>126.312500</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>1</td>\n",
       "      <td>1449</td>\n",
       "      <td>4.5</td>\n",
       "      <td>1256677264</td>\n",
       "      <td>16</td>\n",
       "      <td>125</td>\n",
       "      <td>2021</td>\n",
       "      <td>126.312500</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>499995</th>\n",
       "      <td>5081</td>\n",
       "      <td>2028</td>\n",
       "      <td>3.5</td>\n",
       "      <td>1230508446</td>\n",
       "      <td>33</td>\n",
       "      <td>978</td>\n",
       "      <td>25803</td>\n",
       "      <td>781.909091</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>499996</th>\n",
       "      <td>5081</td>\n",
       "      <td>2053</td>\n",
       "      <td>0.5</td>\n",
       "      <td>1230504222</td>\n",
       "      <td>33</td>\n",
       "      <td>101</td>\n",
       "      <td>25803</td>\n",
       "      <td>781.909091</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>499997</th>\n",
       "      <td>5081</td>\n",
       "      <td>2231</td>\n",
       "      <td>3.5</td>\n",
       "      <td>1230509306</td>\n",
       "      <td>33</td>\n",
       "      <td>141</td>\n",
       "      <td>25803</td>\n",
       "      <td>781.909091</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>499998</th>\n",
       "      <td>5081</td>\n",
       "      <td>2291</td>\n",
       "      <td>4.0</td>\n",
       "      <td>1230509283</td>\n",
       "      <td>33</td>\n",
       "      <td>458</td>\n",
       "      <td>25803</td>\n",
       "      <td>781.909091</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>499999</th>\n",
       "      <td>5081</td>\n",
       "      <td>2329</td>\n",
       "      <td>4.0</td>\n",
       "      <td>1230509222</td>\n",
       "      <td>33</td>\n",
       "      <td>601</td>\n",
       "      <td>25803</td>\n",
       "      <td>781.909091</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>500000 rows × 8 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "        userId  movieId  rating   timestamp  user_vitality  movie_popularity  \\\n",
       "0            1      307     3.5  1256677221             16               167   \n",
       "1            1      481     3.5  1256677456             16               134   \n",
       "2            1     1091     1.5  1256677471             16               107   \n",
       "3            1     1257     4.5  1256677460             16               109   \n",
       "4            1     1449     4.5  1256677264             16               125   \n",
       "...        ...      ...     ...         ...            ...               ...   \n",
       "499995    5081     2028     3.5  1230508446             33               978   \n",
       "499996    5081     2053     0.5  1230504222             33               101   \n",
       "499997    5081     2231     3.5  1230509306             33               141   \n",
       "499998    5081     2291     4.0  1230509283             33               458   \n",
       "499999    5081     2329     4.0  1230509222             33               601   \n",
       "\n",
       "        movie_popularity_sum  movie_pop_ave  \n",
       "0                       2021     126.312500  \n",
       "1                       2021     126.312500  \n",
       "2                       2021     126.312500  \n",
       "3                       2021     126.312500  \n",
       "4                       2021     126.312500  \n",
       "...                      ...            ...  \n",
       "499995                 25803     781.909091  \n",
       "499996                 25803     781.909091  \n",
       "499997                 25803     781.909091  \n",
       "499998                 25803     781.909091  \n",
       "499999                 25803     781.909091  \n",
       "\n",
       "[500000 rows x 8 columns]"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_userId"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "id": "323e2260",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.collections.PathCollection at 0x15d5edd7160>"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYMAAAD4CAYAAAAO9oqkAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuNCwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8QVMy6AAAACXBIWXMAAAsTAAALEwEAmpwYAAAbY0lEQVR4nO3dfZBc1X3m8e+jYYDBNhlhBpc0EpHskpVFYEtmimWLtQvHiaVgG2QqWYuKA1XrKsUuXBXhLe1KS3YRlFWw0dokVNak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7ZC0OimrSdtr/uU2NZBvbKzVzp8t9DuYsb8bSR8GHgLWRMQ7kwyBNk3bI2IUWCqpE3hE0vmTLN4U7Zb0ZeBQROyQdGkxq+Qpm3HtTrkkIg5IOgd4StLLkyxb1bY3Y89gAJifej0POFCnuky3t5MuIcnPQ0l5od/BQPJ8fHlDk9RONgh+GhEPJ8Ut0XaAiBgG/g+wguZv9yXA5ZJeJzvE+7uS7qb52w1ARBxIfh4CHiE77F2TtjdjGPwaWCRpoaRTgVXAtjrXabpsA65Jnl8DPJoqXyXpNEkLgUXA80kX811JFydnF1ydWqchJfX8MfBSRHw/9VZTt11SV9IjQFIH8HvAyzR5uyNifUTMi4gFZP92fxERX6fJ2w0g6UOSPpJ7DnwR2EOt2l7v2fPpeACXkT3rZD9wfb3rU6U23QscBDJkk/8bwEeBp4FXkp9npZa/Pml/P6kzCYCe5D/YfuCvSa5Cb9QH8O/JdnFfAPqSx2XN3nbgU8DOpN17gP+elDd1u8f9Di7lg7OJmr7dZM+A3JU89ub2XbVqu29HYWZmTTlMZGZmJXIYmJmZw8DMzBwGZmaGw8DMzHAYmJkZDgMzMwP+P/LRII4j8+pCAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "df2=df_userId[['userId','user_vitality','movie_pop_ave']].groupby('userId').agg('mean').reset_index()\n",
    "x=df2['user_vitality']\n",
    "y=df2['movie_pop_ave']\n",
    "plt.scatter(x,y)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "id": "ba5583c2",
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "C:\\Users\\dell\\AppData\\Local\\Temp/ipykernel_6620/2081041750.py:2: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame.\n",
      "Try using .loc[row_indexer,col_indexer] = value instead\n",
      "\n",
      "See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  user_vitality['user_vitality']=1\n"
     ]
    }
   ],
   "source": [
    "user_vitality=df[['userId']]\n",
    "user_vitality['user_vitality']=1\n",
    "user_vitality=user_vitality.groupby('userId').agg('sum').reset_index()\n",
    "user_vitality=user_vitality['user_vitality'].value_counts()\n",
    "user_vitality=user_vitality.reset_index()\n",
    "user_vitality.columns=['user_vitality','number']"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 20,
   "id": "d7e172f2",
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "C:\\Users\\dell\\AppData\\Local\\Temp/ipykernel_6620/1433600703.py:2: SettingWithCopyWarning: \n",
      "A value is trying to be set on a copy of a slice from a DataFrame.\n",
      "Try using .loc[row_indexer,col_indexer] = value instead\n",
      "\n",
      "See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy\n",
      "  movie_popularity['movie_popularity']=1\n"
     ]
    }
   ],
   "source": [
    "movie_popularity=df[['movieId']]\n",
    "movie_popularity['movie_popularity']=1\n",
    "movie_popularity=movie_popularity.groupby('movieId').agg('sum').reset_index()\n",
    "movie_popularity=movie_popularity['movie_popularity'].value_counts()\n",
    "movie_popularity=movie_popularity.reset_index()\n",
    "movie_popularity.columns=['movie_popularity','number']"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "id": "2b521290",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>movie_popularity</th>\n",
       "      <th>number</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>5702</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>2111</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>1266</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>4</td>\n",
       "      <td>854</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>5</td>\n",
       "      <td>644</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>522</th>\n",
       "      <td>251</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>523</th>\n",
       "      <td>267</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>524</th>\n",
       "      <td>708</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>525</th>\n",
       "      <td>299</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>526</th>\n",
       "      <td>711</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>527 rows × 2 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "     movie_popularity  number\n",
       "0                   1    5702\n",
       "1                   2    2111\n",
       "2                   3    1266\n",
       "3                   4     854\n",
       "4                   5     644\n",
       "..                ...     ...\n",
       "522               251       1\n",
       "523               267       1\n",
       "524               708       1\n",
       "525               299       1\n",
       "526               711       1\n",
       "\n",
       "[527 rows x 2 columns]"
      ]
     },
     "execution_count": 21,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "movie_popularity"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "id": "cecb90ca",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>user_vitality</th>\n",
       "      <th>number</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>15</td>\n",
       "      <td>344</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>16</td>\n",
       "      <td>183</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>17</td>\n",
       "      <td>131</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>5</td>\n",
       "      <td>130</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>1</td>\n",
       "      <td>112</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>563</th>\n",
       "      <td>1121</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>564</th>\n",
       "      <td>969</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>565</th>\n",
       "      <td>965</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>566</th>\n",
       "      <td>945</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>567</th>\n",
       "      <td>1647</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>568 rows × 2 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "     user_vitality  number\n",
       "0               15     344\n",
       "1               16     183\n",
       "2               17     131\n",
       "3                5     130\n",
       "4                1     112\n",
       "..             ...     ...\n",
       "563           1121       1\n",
       "564            969       1\n",
       "565            965       1\n",
       "566            945       1\n",
       "567           1647       1\n",
       "\n",
       "[568 rows x 2 columns]"
      ]
     },
     "execution_count": 22,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "user_vitality"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "id": "96ef8d4f",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.collections.PathCollection at 0x15d5f3ea490>"
      ]
     },
     "execution_count": 23,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXwAAAD4CAYAAADvsV2wAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuNCwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8QVMy6AAAACXBIWXMAAAsTAAALEwEAmpwYAAAXO0lEQVR4nO3dfWxdd33H8fenrtu60M3p6laJE5auCtlSOhJmpUWdpo4nZ91DzDS0dIPlD7TwR5GoNmWKAY2CGq1bxsOmCaQA1bKttGQjuBGUhRBACGk0c0haJ029Btq1tqPGDDxgtYLrfPfHPU6u4/to3+vr49/nJVn33N95uN9fnX7u8Tm/c44iAjMzW/6uaHUBZma2OBz4ZmaJcOCbmSXCgW9mlggHvplZIq5sdQEAN9xwQ6xdu7bVZZiZ5cqxY8d+EBFdtS6/JAJ/7dq1DA4O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pfqD/DrFP4UfQo4kf3cnUjffxU4nvX9JPCXWfuy73tR3XdxaZTOsu83hZGFT2Y/p2ayazH67lsrmJklIs+HdMzMrA4OfDOzRDjwzcwS4cA3M0uEA9/MLBEOfDOzRDjwzcwS8f+9QSQuCIqSxQAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(user_vitality['user_vitality'],user_vitality['number'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "id": "2d030a1a",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.collections.PathCollection at 0x15d5ffc4c10>"
      ]
     },
     "execution_count": 24,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAX0AAAD4CAYAAAAAczaOAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuNCwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8QVMy6AAAACXBIWXMAAAsTAAALEwEAmpwYAAAWIklEQVR4nO3df2zc9X3H8ecrjqEuLQ0ZBgUnEEBZNmjVUk5AxVqp6w+n0DVZq06h3Yg0tGiISa22ZUvGNFGpqHTRqg5NMNEWEQYFMjWErCtNo6xbpSlAHQI1AbyYQiF2lqQ/vGbDosa898d9HL6x7853jn3n3Of1kE739fu+P973tfPK19/vx/dVRGBmZnlY0OoGzMyseRz6ZmYZceibmWXEoW9mlhGHvplZRha2uoHpnH322bF8+fJWt2FmdkrZu3fvTyOie3J93of+8uXL6evra3UbZmanFEk/qVT36R0zs4w49M3MMuLQNzPLiEPfzCwjDn0zs4zM+9E7M7F93xCbdw4wPDLKeYu62NC7kjWX9bS6LTOzlmu70N++b4hN2/oZHRsHYGhklE3b+gEc/GaWvbY7vbN558DxwJ8wOjbO5p0DLerIzGz+aLvQHx4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PpEHB+RFwG/CnwTUln0tpeG/2et3y/Atdx4oFKU/ZrO4Z+y26+XoukTsqBf39EbAOIiMMRMR4RbwBf481TDS19DxExnJ6PAA+nvg6nXzMnft08Mh96TT4GPBkRh2H+7tek0f14kBNPqzS1Z0nrgI8Dn02nFkinSn6WpvdSPk/+663sdQbf81bv14XAJ4GHJmrN2q/tGPrHb76ejgDXAjta2VA6d/cN4LmI+EqhvqQw2+8CE1f4dwBrJZ2u8k3kV1C+kNOMXs+Q9PaJacoX855JPa1Ls60DHml1rwUnHDHNx/1a0NB+TKeAjkm6Kv0cXV9YZk5JWgX8JfCJiHi1UO+W1JGmL0q9/rjFvTb0PW9lr8mHgecj4vhpm6bt19m+Wj0fHsA1lEfIvADcPA/6+S3Kv479CHgqPa4B/gnoT/UdwJLCMjen/geYg1EFNXq9iPJoh6eB/RP7D/g1YDdwID0vbnWvadtvBX4GvKNQmxf7lfJ/RIeAMcpHazfMZD8CJcoh9gLwD6S/pG9Cr4OUz4dP/Mz+Y5r3U+ln42ngSeB35kGvDX/PW9Vrqt8D/PGkeZuyX/0xDGZmGWnH0ztmZlaFQ9/MLCMOfTOzjDj0zcwy4tA3M8uIQ9/MLCMOfTOzjPw/LZqEs0Xjz2QAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(movie_popularity['movie_popularity'],movie_popularity['number'])"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.12"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
